<html>
<head><meta charset="utf-8"><title>Const generics infer; review session ii · t-compiler · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/index.html">t-compiler</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html">Const generics infer; review session ii</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="163934247"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163934247" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Charles Lew <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163934247">(Apr 22 2019 at 20:19)</a>:</h4>
<p>Just wake up to check up the progress with the const generics. Did the review session happen today? <span class="user-mention" data-user-id="116009">@nikomatsakis</span></p>



<a name="163940055"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163940055" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163940055">(Apr 22 2019 at 21:28)</a>:</h4>
<p><span class="user-mention" data-user-id="116458">@Charles Lew</span> I didn't get to it, I was about to post a comment that I fell behind :(</p>



<a name="163940058"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163940058" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163940058">(Apr 22 2019 at 21:28)</a>:</h4>
<p>I may yet</p>



<a name="163940727"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163940727" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163940727">(Apr 22 2019 at 21:36)</a>:</h4>
<p>I added a test, but the other tests (that were working on <a href="https://github.com/rust-lang/rust/issues/53645" target="_blank" title="https://github.com/rust-lang/rust/issues/53645">#53645</a>) seem not to be working with the latest infer changes, so I haven't added them yet</p>



<a name="163940769"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163940769" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163940769">(Apr 22 2019 at 21:37)</a>:</h4>
<p>I haven't got around to checking whether it's because there are still some missing things in the infer PR, or whether something has broken in the meantime</p>



<a name="163946783"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163946783" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163946783">(Apr 22 2019 at 23:08)</a>:</h4>
<p>(I've added another test)</p>



<a name="163983868"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163983868" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163983868">(Apr 23 2019 at 12:24)</a>:</h4>
<p>okay, there are a few tests there now</p>



<a name="163985787"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/163985787" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> eddyb <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#163985787">(Apr 23 2019 at 12:48)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> fwiw, the more unblocking thing to do is answering point-wise questions about the type/trait/infer system, in light of recent changes</p>



<a name="164046527"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164046527" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Charles Lew <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164046527">(Apr 24 2019 at 02:07)</a>:</h4>
<p>Mmm, did the session rescheduled again?</p>



<a name="164099466"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164099466" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Charles Lew <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164099466">(Apr 24 2019 at 17:04)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> a ping to make sure the review session actually get rescheduled.</p>



<a name="164104475"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164104475" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164104475">(Apr 24 2019 at 18:03)</a>:</h4>
<p>Update: I spent some time reading it but didn't get as far as I would like.</p>



<a name="164110142"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164110142" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164110142">(Apr 24 2019 at 19:04)</a>:</h4>
<p><span class="user-mention" data-user-id="121053">@varkor</span> so I was playing with this test case, and it doesn't compile</p>
<div class="codehilite"><pre><span></span><span class="cp">#![feature(const_generics)]</span><span class="w"></span>

<span class="k">fn</span> <span class="nf">foo</span><span class="o">&lt;</span><span class="k">const</span><span class="w"> </span><span class="n">C</span>: <span class="kt">usize</span><span class="o">&gt;</span><span class="p">(</span><span class="n">x</span>: <span class="p">[</span><span class="kt">u8</span><span class="p">;</span><span class="w"> </span><span class="n">C</span><span class="p">])</span><span class="w"> </span><span class="p">{</span><span class="w"> </span><span class="p">}</span><span class="w"></span>

<span class="k">fn</span> <span class="nf">main</span><span class="p">()</span><span class="w"> </span><span class="p">{</span><span class="w"></span>
<span class="w">    </span><span class="kd">let</span><span class="w"> </span><span class="n">data</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="p">[</span><span class="mi">1</span><span class="p">,</span><span class="w"> </span><span class="mi">2</span><span class="p">,</span><span class="w"> </span><span class="mi">3</span><span class="p">];</span><span class="w"></span>
<span class="w">    </span><span class="n">foo</span><span class="p">(</span><span class="n">data</span><span class="p">);</span><span class="w"></span>
<span class="p">}</span><span class="w"></span>
</pre></div>



<a name="164110219"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164110219" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164110219">(Apr 24 2019 at 19:04)</a>:</h4>
<p>I guess this is known to you :)</p>



<a name="164110277"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164110277" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164110277">(Apr 24 2019 at 19:04)</a>:</h4>
<p>the error I get is</p>
<div class="codehilite"><pre><span></span>error[E0282]: type annotations needed
 --&gt; /home/nmatsakis/tmp/const-generics-1.rs:7:5
  |
7 |     foo(data);
  |     ^^^ cannot infer type for `fn([u8; _]) {foo::&lt;_&gt;}`
</pre></div>



<a name="164110292"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164110292" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164110292">(Apr 24 2019 at 19:05)</a>:</h4>
<p>I guess I have to trace through the code, presumably the unification logic is either missing or disabled</p>



<a name="164111073"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164111073" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164111073">(Apr 24 2019 at 19:15)</a>:</h4>
<p>OK, well, I guess the problem is <a href="https://github.com/rust-lang/rust/blob/e305df1846a6d985315917ae0c81b74af8b4e641/src/librustc/ty/relate.rs#L504-L517" target="_blank" title="https://github.com/rust-lang/rust/blob/e305df1846a6d985315917ae0c81b74af8b4e641/src/librustc/ty/relate.rs#L504-L517">the <code>relate</code> logic here</a></p>



<a name="164111297"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164111297" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164111297">(Apr 24 2019 at 19:18)</a>:</h4>
<p>Is it expected that this test ICEs and gives other errors?</p>
<div class="codehilite"><pre><span></span><span class="k">struct</span> <span class="nc">Foo</span><span class="o">&lt;</span><span class="k">const</span><span class="w"> </span><span class="n">C</span>: <span class="kt">usize</span><span class="o">&gt;</span><span class="w"> </span><span class="p">{</span><span class="w"></span>
<span class="w">    </span><span class="n">data</span>: <span class="kt">usize</span>
<span class="p">}</span><span class="w"></span>

<span class="k">fn</span> <span class="nf">foo</span><span class="o">&lt;</span><span class="k">const</span><span class="w"> </span><span class="n">C</span>: <span class="kt">usize</span><span class="o">&gt;</span><span class="p">(</span><span class="n">x</span>: <span class="nc">Foo</span><span class="o">&lt;</span><span class="n">C</span><span class="o">&gt;</span><span class="p">)</span><span class="w"> </span><span class="p">{</span><span class="w"> </span><span class="p">}</span><span class="w"></span>
<span class="c1">// compiler doesn&#39;t really like the `Foo&lt;C&gt;` there</span>

<span class="k">fn</span> <span class="nf">main</span><span class="p">()</span><span class="w"> </span><span class="p">{</span><span class="w"></span>
<span class="w">    </span><span class="kd">let</span><span class="w"> </span><span class="n">data</span>: <span class="nc">Foo</span><span class="o">&lt;</span><span class="mi">3</span><span class="o">&gt;</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">Foo</span>::<span class="o">&lt;</span><span class="mi">3</span><span class="o">&gt;</span><span class="w"> </span><span class="p">{</span><span class="w"> </span><span class="n">data</span>: <span class="mi">22</span><span class="w"> </span><span class="p">};</span><span class="w"></span>
<span class="w">    </span><span class="n">foo</span><span class="p">(</span><span class="n">data</span><span class="p">);</span><span class="w"></span>
<span class="p">}</span><span class="w"></span>
</pre></div>



<a name="164112807"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112807" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112807">(Apr 24 2019 at 19:36)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span>: it's known that quite a few things don't work</p>



<a name="164112839"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112839" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112839">(Apr 24 2019 at 19:36)</a>:</h4>
<p>some are due to the questions in the RFC</p>



<a name="164112850"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112850" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112850">(Apr 24 2019 at 19:36)</a>:</h4>
<p>others are probably oversights</p>



<a name="164112883"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112883" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112883">(Apr 24 2019 at 19:37)</a>:</h4>
<p>I'm not sure what the best way forward is — that is, whether we want to get everything working before merging, or fix problems as follow ups</p>



<a name="164112898"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112898" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112898">(Apr 24 2019 at 19:37)</a>:</h4>
<p>the latter is probably less hassle</p>



<a name="164112981"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164112981" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164112981">(Apr 24 2019 at 19:38)</a>:</h4>
<p>I have a few extra tests that ICE (that I haven't added to the PR) that I know about</p>



<a name="164113018"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164113018" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164113018">(Apr 24 2019 at 19:39)</a>:</h4>
<p>but some simple tests are passing now, at least :)</p>



<a name="164113198"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164113198" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164113198">(Apr 24 2019 at 19:41)</a>:</h4>
<blockquote>
<p>I'm not sure what the best way forward is — that is, whether we want to get everything working before merging, or fix problems as follow ups</p>
</blockquote>
<p>probably best to merge bit by bit. I am just sort of trying to wrap my head around what this PR itself enables</p>



<a name="164113208"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164113208" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164113208">(Apr 24 2019 at 19:41)</a>:</h4>
<p>anyway I think I'll try to review eddyb's specific questions</p>



<a name="164296258"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164296258" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164296258">(Apr 26 2019 at 20:42)</a>:</h4>
<p>Hey <span class="user-mention" data-user-id="121053">@varkor</span> <span class="user-mention" data-user-id="218608">@yodal</span>! On Github <a href="https://github.com/rust-lang/rust/pull/59008#issuecomment-487194356" target="_blank" title="https://github.com/rust-lang/rust/pull/59008#issuecomment-487194356">I wrote</a>:</p>
<blockquote>
<p>maybe we can sync up a bit next week and you can try to talk me through it? (Over Zulip would be fine.) I'm interested in having the design here written out and submitted as a proposal. Anyway, I'll ping you on Zulip to discuss.</p>
</blockquote>
<p>So this is me pinging you both =) what do you think?</p>



<a name="164296592"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164296592" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164296592">(Apr 26 2019 at 20:47)</a>:</h4>
<p>sounds good <span aria-label="+1" class="emoji emoji-1f44d" role="img" title="+1">:+1:</span><br>
it'd be useful to make sure <span class="user-mention" data-user-id="119009">@eddyb</span> is available too, as the overarching strategy for the PRs was <a href="https://github.com/rust-lang/rust/issues/44580#issuecomment-330154745" target="_blank" title="https://github.com/rust-lang/rust/issues/44580#issuecomment-330154745">following the guidelines here</a> and doing something analogous to type parameters by default</p>



<a name="164296680"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164296680" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164296680">(Apr 26 2019 at 20:48)</a>:</h4>
<p>regarding the specific comments: as we discussed previously, there's definitely opportunity for refactoring afterwards, but that can be considered mostly as a separate issue</p>



<a name="164296746"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164296746" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164296746">(Apr 26 2019 at 20:49)</a>:</h4>
<p>canonicalisation is one of the trickier parts, so I imagine there are some kinks to work out there (though as you say, I'm not sure whether it's worth addressing in this PR, or afterwards)</p>



<a name="164297031"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164297031" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164297031">(Apr 26 2019 at 20:53)</a>:</h4>
<p>thanks for reviewing :)</p>



<a name="164299320"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164299320" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> yodal <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164299320">(Apr 26 2019 at 21:28)</a>:</h4>
<p>I am also up for sitting down for a chat. That said, I am not sure how much I can add other than to say that we followed the patterns in what was already done.</p>



<a name="164299391"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164299391" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> yodal <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164299391">(Apr 26 2019 at 21:29)</a>:</h4>
<p>Cannonicalization is definitely just past where I have been comfortable working because I don't quite understand everything that is going on from a bigger picture</p>



<a name="164299489"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164299489" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> yodal <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164299489">(Apr 26 2019 at 21:30)</a>:</h4>
<p>Also, I haven't been lurking on Zulip because I only used it for the last review session, but I will try to stick around so that you can reach me</p>



<a name="164518467"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164518467" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> eddyb <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164518467">(Apr 30 2019 at 07:44)</a>:</h4>
<p>I vaguely understand canonicalization, but I'm not comfortable with edge cases</p>



<a name="164518481"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164518481" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> eddyb <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164518481">(Apr 30 2019 at 07:45)</a>:</h4>
<p>as in, I think I know how to make <em>some</em> things work, but not how to keep everything sound etc.</p>



<a name="164579447"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/Const%20generics%20infer%3B%20review%20session%20ii/near/164579447" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/Const.20generics.20infer.3B.20review.20session.20ii.html#164579447">(Apr 30 2019 at 21:41)</a>:</h4>
<p>I've fixed the remaining issue with <code>shallow_resolve</code>, so I think there are just the questions about canonicalisation to go?</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>